package cn.rslee.uaas.entity;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

@Entity 
@Table(name = "UAAS_REPORT_ACCESS_DAY") 
public class AccessDay implements Serializable  {

	/**
	 * 
	 */
	private static final long serialVersionUID = 882974279193342373L;
	
	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY)
	@Column(name="ID")
	private Long id;
	
	@Column(name = "SYS_CODE")
	private String sysCode;  //系统编码
	
	@Column(name = "PV")
	private int pv;  //访问量
	
	@Column(name = "UV")
	private int uv;  //用户量
	
	@Column(name = "IP")
	private int ip;  //IP数
	
	@Column(name = "DAYS")
	@Temporal(TemporalType.DATE)
	private Date days;  //统计日期
	

	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public int getPv() {
		return pv;
	}

	public void setPv(int pv) {
		this.pv = pv;
	}

	public int getUv() {
		return uv;
	}

	public void setUv(int uv) {
		this.uv = uv;
	}

	public int getIp() {
		return ip;
	}

	public void setIp(int ip) {
		this.ip = ip;
	}

	public Date getDays() {
		return days;
	}

	public void setDays(Date days) {
		this.days = days;
	}
	
	public String getSysCode() {
		return sysCode;
	}

	public void setSysCode(String sysCode) {
		this.sysCode = sysCode;
	}

	public AccessDay(String sysCode, int pv, int uv, int ip, Date days) {
		super();
		this.sysCode = sysCode;
		this.pv = pv;
		this.uv = uv;
		this.ip = ip;
		this.days = days;
	}

	public AccessDay() {
		super();
		// TODO Auto-generated constructor stub
	}

	@Override
	public String toString() {
		return "AccessDay [id=" + id + ", sysCode=" + sysCode + ", pv=" + pv
				+ ", uv=" + uv + ", ip=" + ip + ", days=" + days + "]";
	}

}
